package com.chao.ClientSocket;

import java.io.IOException;
import java.net.Socket;

public class SocketOptions {

    public static void main(String[] args) throws IOException {
        Socket socket=new Socket("www.baidu.com",80);
        if(!socket.getTcpNoDelay()) socket.setTcpNoDelay(true);

        socket.setReceiveBufferSize(1024);
        socket.setSendBufferSize(1024);
        System.out.println(socket.getReceiveBufferSize());
        System.out.println(socket.getSendBufferSize());


        socket.getReuseAddress();
        //socket.setPerformancePreferences();

        socket.close();
    }
}
